package view;

import java.text.NumberFormat;
import model.LocalVare;

public class VareLinieForm extends javax.swing.JPanel {

     
     private Client gui; 
     LocalVare lv;
    
    public VareLinieForm( Client gui, LocalVare lv ) {
        initComponents();
        this.gui = gui;
        this.lv = lv;
        jLabel_varenavn.setText(lv.getVareNavn());
        jLabel_salgspris.setText( "Salg: "+lv.getSalgsprisris());
        jLabel_antal.setText( ""+lv.getAntal());
        NumberFormat fmt = NumberFormat.getCurrencyInstance();
        jLabel_indpris.setText( "Købs: " + lv.getIndkøbsPris());
         jLabel_avance.setText( "Avc: " + lv.getAvance());
    }

    /**
     * This method is called from within the constructor to initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is always
     * regenerated by the Form Editor.
     */
    @SuppressWarnings("unchecked")
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {

        jLabel_varenavn = new javax.swing.JLabel();
        jLabel_indpris = new javax.swing.JLabel();
        jLabel_salgspris = new javax.swing.JLabel();
        jLabel_antal = new javax.swing.JLabel();
        jLabel_avance = new javax.swing.JLabel();

        setLayout(null);

        jLabel_varenavn.setText("dd");
        add(jLabel_varenavn);
        jLabel_varenavn.setBounds(0, 0, 70, 30);

        jLabel_indpris.setText("jLabel1");
        add(jLabel_indpris);
        jLabel_indpris.setBounds(90, 0, 80, 30);

        jLabel_salgspris.setText("jLabel1");
        add(jLabel_salgspris);
        jLabel_salgspris.setBounds(170, 0, 80, 30);

        jLabel_antal.setText("jLabel1");
        add(jLabel_antal);
        jLabel_antal.setBounds(310, 0, 60, 30);

        jLabel_avance.setText("jLabel1");
        add(jLabel_avance);
        jLabel_avance.setBounds(250, 0, 50, 30);
    }// </editor-fold>//GEN-END:initComponents

    // Variables declaration - do not modify//GEN-BEGIN:variables
    private javax.swing.JLabel jLabel_antal;
    private javax.swing.JLabel jLabel_avance;
    private javax.swing.JLabel jLabel_indpris;
    private javax.swing.JLabel jLabel_salgspris;
    private javax.swing.JLabel jLabel_varenavn;
    // End of variables declaration//GEN-END:variables
}
